home *** CD-ROM | disk | FTP | other *** search
/ Meeting Pearls 4 / Meeting Pearls Vol. IV (1996)(GTI - Schatztruhe)[!].iso / Pearls / libs / bgui / Include / libraries / bgui_macros.i < prev    next >
Text File  |  1995-06-11  |  30KB  |  1,484 lines

  1.         IFND    LIBRARIES_BGUI_MACROS_I
  2. LIBRARIES_BGUI_MACROS_I SET    1
  3. **
  4. **    $VER: libraries/bgui_macros.i 38.4 (11.6.95)
  5. **    bgui.library macros.
  6. **
  7. **    (C) Copyright 1993-1995 Jaba Development.
  8. **    (C) Copyright 1993-1995 Jan van den Baard.
  9. **        All Rights Reserved.
  10. **
  11.  
  12.         IFND    LIBRARIES_BGUI_I
  13.         include 'libraries/bgui.i'
  14.         ENDC    ; LIBARIES_BGUI_I
  15.  
  16.         IFND    LIBRARIES_BGUI_OFFSETS_I
  17.         include 'libraries/bgui.i'
  18.         ENDC    ; LIBRARIES_BGUI_OFFSETS_I
  19.  
  20.         ;
  21.         ;    STACK arg
  22.         ;
  23.         ;    If 'arg' is a valid argument this macro will
  24.         ;    put it on the stack increasing the constant
  25.         ;    'STACKSIZE' with 4. This macro is used by the
  26.         ;    DOMETHOD macro below.
  27.         ;
  28. STACK        MACRO
  29.         IFNC    '\1',''
  30.         move.l    \1,-(sp)
  31. STACKSIZE    SET    STACKSIZE+4
  32.         ENDC
  33.         ENDM
  34.  
  35.         ;
  36.         ;    DOMETHOD object,methodID[,...]
  37.         ;
  38.         ;    This macro invokes method 'methodID' on object 'object'.
  39.         ;    Upto eight extra arguments may be passed to the macro.
  40.         ;    This should be suffiecient for most methods.
  41.         ;
  42. DOMETHOD    MACRO
  43.         IFLT    NARG-2
  44.         FAIL    'Need at least TWO parameters in the "DOMETHOD" macro!'
  45.         MEXIT
  46.         ENDC
  47. STACKSIZE    SET    0
  48.         movem.l a0-a2,-(sp)        ; save regs
  49.         STACK    \9
  50.         STACK    \8
  51.         STACK    \7
  52.         STACK    \6
  53.         STACK    \5
  54.         STACK    \4
  55.         STACK    \3
  56.         STACK    \2
  57.         move.l    \1,a2            ; object in a2
  58.         move.l    sp,a1            ; msg in a1
  59.         move.l    -4(a2),a0        ; class in a0
  60.         pea    DOMETHOD\@(pc)        ; return address class dispatcher
  61.         move.l    8(a0),-(sp)        ; stack dispatcher entry
  62.         rts                ; call dispatcher
  63. DOMETHOD\@    lea.l    STACKSIZE(sp),sp    ; align stack
  64.         movem.l (sp)+,a0-a2        ; restore regs
  65.         ENDM
  66.  
  67.         ;
  68.         ;    DOGADGETMETHOD object,win,req,methodID[,...]
  69.         ;
  70.         ;    This macro invokes method 'methodID' on object 'object'.
  71.         ;    Upto six extra arguments may be passed to the macro.
  72.         ;    This should be suffiecient for most methods. This call
  73.         ;    uppon BGUI_DoGadgetMethodA so BGUI must be in a6!
  74.         ;
  75. DOGADGETMETHOD    MACRO
  76.         IFLT    NARG-4
  77.         FAIL    'Need at least FOUR parameters in the "DOGADGETMETHOD" macro!'
  78.         MEXIT
  79.         ENDC
  80. STACKSIZE    SET    0
  81.         movem.l a0-a3,-(sp)        ; save regs
  82.         STACK    \9
  83.         STACK    \8
  84.         STACK    \7
  85.         STACK    \6
  86.         STACK    \5
  87.         STACK    \4
  88.         move.l    \1,a0            ; object in a0
  89.         move.l    \2,a1            ; window in a1
  90.         move.l    \3,a2            ; requester in a2
  91.         move.l    sp,a3            ; msg in a3
  92.         jsr    _LVOBGUI_DoGadgetMethodA(a6)
  93.         lea.l    STACKSIZE(sp),sp    ; align stack
  94.         movem.l (sp)+,a0-a3        ; restore regs
  95.         ENDM
  96.  
  97.         ;
  98.         ;    INIT
  99.         ;
  100.         ;    This macro sets things up for a object creation
  101.         ;    macro.
  102.         ;
  103. INIT        MACRO
  104.         movem.l d2/a2,-(sp)
  105.         move.l    sp,a2            ; save stack address
  106.         move.l    #TAG_DONE,-(sp)
  107.         ENDM
  108.  
  109.         ;
  110.         ;    EXIT
  111.         ;
  112.         ;    This macro sets things back to their original
  113.         ;    state after an object creation.
  114.         ;
  115. EXIT        MACRO
  116.         move.l    a2,sp            ; put pack stack address
  117.         movem.l (sp)+,d2/a2
  118.         ENDM
  119.  
  120.         ;
  121.         ;    SC arg
  122.         ;
  123.         ;    Put the argument of this macro on the stack
  124.         ;    as a constant if it is a valid argument.
  125.         ;
  126. SC        MACRO
  127.         IFNC    '\1',''
  128.         IFC    '\1','0'
  129.         clr.l    -(sp)
  130.         ELSEIF
  131.         move.l    #\1,-(sp)
  132.         ENDC
  133.         ENDC
  134.         ENDM
  135.  
  136.         ;
  137.         ;    SV arg
  138.         ;
  139.         ;    Put the argument of this macro on the stack
  140.         ;    if it is a valid argument.
  141.         ;
  142. SV        MACRO
  143.         IFNC    '\1',''
  144.         IFC    '\1','#0'
  145.         clr.l    -(sp)
  146.         ELSEIF
  147.         move.l    \1,-(sp)
  148.         ENDC
  149.         ENDC
  150.         ENDM
  151.  
  152.         ;
  153.         ;    PUTC arg1[,...,arg15]
  154.         ;
  155.         ;    Put upto 15 arguments as constants on the stack.
  156.         ;
  157. PUTC        MACRO
  158.         SC    \F
  159.         SC    \E
  160.         SC    \D
  161.         SC    \C
  162.         SC    \B
  163.         SC    \A
  164.         SC    \9
  165.         SC    \8
  166.         SC    \7
  167.         SC    \6
  168.         SC    \5
  169.         SC    \4
  170.         SC    \3
  171.         SC    \2
  172.         SC    \1
  173.         ENDM
  174.  
  175.         ;
  176.         ;    PUTV arg1[,...,arg15]
  177.         ;
  178.         ;    Put upto 15 arguments on the stack.
  179.         ;
  180. PUTV        MACRO
  181.         SV    \F
  182.         SV    \E
  183.         SV    \D
  184.         SV    \C
  185.         SV    \B
  186.         SV    \A
  187.         SV    \9
  188.         SV    \8
  189.         SV    \7
  190.         SV    \6
  191.         SV    \5
  192.         SV    \4
  193.         SV    \3
  194.         SV    \2
  195.         SV    \1
  196.         ENDM
  197.  
  198. ******************************************************************************
  199. *    General object creation macros.
  200. ******************************************************************************
  201.  
  202. INITOBJ         MACRO    ; type
  203.         INIT
  204.         moveq.l #\1,d2
  205.         ENDM
  206.  
  207. HGroupObject    MACRO
  208.         INITOBJ BGUI_GROUP_GADGET
  209.         PUTC    GROUP_Inverted,1
  210.         ENDM
  211.  
  212. VGroupObject    MACRO
  213.         INITOBJ BGUI_GROUP_GADGET
  214.         PUTC    GROUP_Style,GRSTYLE_VERTICAL,GROUP_Inverted,1
  215.         ENDM
  216.  
  217. ButtonObject    MACRO
  218.         INITOBJ BGUI_BUTTON_GADGET
  219.         ENDM
  220.  
  221. ToggleObject    MACRO
  222.         INITOBJ BGUI_BUTTON_GADGET
  223.         PUTC    GA_ToggleSelect,1
  224.         ENDM
  225.  
  226. CycleObject    MACRO
  227.         INITOBJ BGUI_CYCLE_GADGET
  228.         ENDM
  229.  
  230. CheckBoxObject    MACRO
  231.         INITOBJ BGUI_CHECKBOX_GADGET
  232.         ENDM
  233.  
  234. InfoObject    MACRO
  235.         INITOBJ BGUI_INFO_GADGET
  236.         ENDM
  237.  
  238. StringObject    MACRO
  239.         INITOBJ BGUI_STRING_GADGET
  240.         ENDM
  241.  
  242. PropObject    MACRO
  243.         INITOBJ BGUI_PROP_GADGET
  244.         ENDM
  245.  
  246. IndicatorObject MACRO
  247.         INITOBJ BGUI_INDICATOR_GADGET
  248.         ENDM
  249.  
  250. ProgressObject    MACRO
  251.         INITOBJ BGUI_PROGRESS_GADGET
  252.         ENDM
  253.  
  254. SliderObject    MACRO
  255.         INITOBJ BGUI_SLIDER_GADGET
  256.         ENDM
  257.  
  258. PageObject    MACRO
  259.         INITOBJ BGUI_PAGE_GADGET
  260.         PUTC    PAGE_Inverted,1
  261.         ENDM
  262.  
  263. MxObject    MACRO
  264.         INITOBJ BGUI_MX_GADGET
  265.         ENDM
  266.  
  267. ListviewObject    MACRO
  268.         INITOBJ BGUI_LISTVIEW_GADGET
  269.         ENDM
  270.  
  271. ExternalObject    MACRO
  272.         INITOBJ BGUI_EXTERNAL_GADGET
  273.         PUTC    GA_Left,0,GA_Top,0,GA_Width,0,GA_Height,0
  274.         ENDM
  275.  
  276. SeperatorObject MACRO
  277.         INITOBJ BGUI_SEPERATOR_GADGET
  278.         ENDM
  279.  
  280. WindowObject    MACRO
  281.         INITOBJ BGUI_WINDOW_OBJECT
  282.         ENDM
  283.  
  284. FileReqObject    MACRO
  285.         INITOBJ BGUI_FILEREQ_OBJECT
  286.         ENDM
  287.  
  288. CommodityObject MACRO
  289.         INITOBJ BGUI_COMMODITY_OBJECT
  290.         ENDM
  291.  
  292. EndObject    MACRO
  293.         move.l    sp,a0
  294.         move.l    d2,d0
  295.         jsr    _LVOBGUI_NewObjectA(a6)
  296.         EXIT
  297.         ENDM
  298.  
  299. ** Typo
  300. SeparatorObject MACRO
  301.         INITOBJ BGUI_SEPARATOR_GADGET
  302.         ENDM
  303.  
  304. ******************************************************************************
  305. *    Label creation.
  306. ******************************************************************************
  307.  
  308. xLabel        MACRO    ; label
  309.         PUTC    LAB_Label,\1
  310.         ENDM
  311.  
  312. UScoreLabel    MACRO    ; label,uchar
  313.         PUTC    LAB_Underscore,\2
  314.         PUTC    LAB_Label,\1
  315.         ENDM
  316.  
  317. Style        MACRO    ; style
  318.         PUTC    LAB_Style,\1
  319.         ENDM
  320.  
  321. Place        MACRO    ; place
  322.         PUTC    LAB_Place,\1
  323.         ENDM
  324.  
  325. ******************************************************************************
  326. *    Frames.
  327. ******************************************************************************
  328. ButtonFrame    MACRO
  329.         PUTC    FRM_Type,FRTYPE_BUTTON
  330.         ENDM
  331.  
  332. RidgeFrame    MACRO
  333.         PUTC    FRM_Type,FRTYPE_RIDGE
  334.         ENDM
  335.  
  336. DropBoxFrame    MACRO
  337.         PUTC    FRM_Type,FRTYPE_DROPBOX
  338.         ENDM
  339.  
  340. NeXTFrame    MACRO
  341.         PUTC    FRM_Type,FRTYPE_NEXT
  342.         ENDM
  343.  
  344. RadioFrame    MACRO
  345.         PUTC    FRM_Type,FRTYPE_RADIOBUTTON
  346.         ENDM
  347.  
  348. XenFrame    MACRO
  349.         PUTC    FRM_Type,FRTYPE_XEN_BUTTON
  350.         ENDM
  351.  
  352. FrameTitle    MACRO    ; title
  353.         PUTC    FRM_Title,\1
  354.         ENDM
  355.  
  356. ShineRaster    MACRO
  357.         PUTC    FRM_BackFill,SHINE_RASTER
  358.         ENDM
  359.  
  360. ShadowRaster    MACRO
  361.         PUTC    FRM_BackFill,SHADOW_RASTER
  362.         ENDM
  363.  
  364. ShineShadowRaster MACRO
  365.         PUTC    FRM_BackFill,SHINE_SHADOW_RASTER
  366.         ENDM
  367.  
  368. FillRaster    MACRO
  369.         PUTC    FRM_BackFill,FILL_RASTER
  370.         ENDM
  371.  
  372. ShineFillRaster MACRO
  373.         PUTC    FRM_BackFill,SHINE_FILL_RASTER
  374.         ENDM
  375.  
  376. ShadowFillRaster MACRO
  377.         PUTC    FRM_BackFill,SHADOW_FILL_RASTER
  378.         ENDM
  379.  
  380. ShineBlock    MACRO
  381.         PUTC    FRM_BackFill,SHINE_BLOCK
  382.         ENDM
  383.  
  384. ShadowBlock    MACRO
  385.         PUTC    FRM_BackFill,SHADOW_BLOCK
  386.         ENDM
  387.  
  388. ******************************************************************************
  389. *      Vector images.
  390. ******************************************************************************
  391.  
  392. GetPath         MACRO
  393.         PUTC    VIT_BuiltIn,BUILTIN_GETPATH
  394.         ENDM
  395.  
  396. GetFile         MACRO
  397.         PUTC    VIT_BuiltIn,BUILTIN_GETFILE
  398.         ENDM
  399.  
  400. CheckMark    MACRO
  401.         PUTC    VIT_BuiltIn,BUILTIN_CHECKMARK
  402.         ENDM
  403.  
  404. PopUp        MACRO
  405.         PUTC    VIT_BuiltIn,BUILTIN_POPUP
  406.         ENDM
  407.  
  408. ArrowUp         MACRO
  409.         PUTC    VIT_BuiltIn,BUILTIN_ARROW_UP
  410.         ENDM
  411.  
  412. ArrowDown    MACRO
  413.         PUTC    VIT_BuiltIn,BUILTIN_ARROW_DOWN
  414.         ENDM
  415.  
  416. ArrowLeft    MACRO
  417.         PUTC    VIT_BuiltIn,BUILTIN_ARROW_LEFT
  418.         ENDM
  419.  
  420. ArrowRight    MACRO
  421.         PUTC    VIT_BuiltIn,BUILTIN_ARROW_RIGHT
  422.         ENDM
  423.  
  424. ******************************************************************************
  425. *      Group class macros.
  426. ******************************************************************************
  427.  
  428. StartMember    MACRO
  429.         ENDM
  430.  
  431. EndMember    MACRO    ; [macro1,arg1,macro2,arg2,macro3,...]
  432.         clr.l    -(sp)
  433.         clr.l    -(sp)
  434.         \1    \2
  435.         \3    \4
  436.         \5    \6
  437.         \7    \8
  438.         \9    \A
  439.         \B    \C
  440.         \D    \E
  441.         PUTV    #GROUP_Member,d0
  442.         ENDM
  443.  
  444. Spacing         MACRO    ; spacing
  445.         PUTC    GROUP_Spacing,\1
  446.         ENDM
  447.  
  448. HOffset         MACRO    ; offset
  449.         PUTC    GROUP_HorizOffset,\1
  450.         ENDM
  451.  
  452. VOffset         MACRO    ; offset
  453.         PUTC    GROUP_VertOffset,\1
  454.         ENDM
  455.  
  456. LOffset         MACRO    ; offset
  457.         PUTC    GROUP_LeftOffset,\1
  458.         ENDM
  459.  
  460. ROffset         MACRO    ; offset
  461.         PUTC    GROUP_RightOffset,\1
  462.         ENDM
  463.  
  464. TOffset         MACRO    ; offset
  465.         PUTC    GROUP_TopOffset,\1
  466.         ENDM
  467.  
  468. BOffset         MACRO    ; offset
  469.         PUTC    GROUP_BottomOffset,\1
  470.         ENDM
  471.  
  472. VarSpace    MACRO    ; weight
  473.         PUTC    GROUP_SpaceObject,\1
  474.         ENDM
  475.  
  476. EqualWidth    MACRO
  477.         PUTC    GROUP_EqualWidth,1
  478.         ENDM
  479.  
  480. EqualHeight    MACRO
  481.         PUTC    GROUP_EqualHeight,1
  482.         ENDM
  483.  
  484. ******************************************************************************
  485. *      Layout macros.
  486. ******************************************************************************
  487.  
  488. FixMinWidth    MACRO
  489.         PUTC    LGO_FixMinWidth,1
  490.         ENDM
  491.  
  492. FixMinHeight    MACRO
  493.         PUTC    LGO_FixMinHeight,1
  494.         ENDM
  495.  
  496. Weight        MACRO    ; weight
  497.         PUTC    LGO_Weight,\1
  498.         ENDM
  499.  
  500. FixWidth    MACRO    ; width
  501.         PUTC    LGO_FixWidth,\1
  502.         ENDM
  503.  
  504. FixHeight    MACRO    ; height
  505.         PUTC    LGO_FixHeight,\1
  506.         ENDM
  507.  
  508. Align        MACRO
  509.         PUTC    LGO_Align,1
  510.         ENDM
  511.  
  512. FixMinSize    MACRO
  513.         PUTC    LGO_FixMinWidth,1,LGO_FixMinHeight,1
  514.         ENDM
  515.  
  516. FixSize         MACRO    ; width, height
  517.         PUTC    LGO_FixWidth,\1,LGO_FixHeight,\2
  518.         ENDM
  519.  
  520. NoAlign         MACRO
  521.         PUTC    LGO_NoAlign,1
  522.         ENDM
  523.  
  524. ******************************************************************************
  525. *      Page class macros.
  526. ******************************************************************************
  527.  
  528. PageMember    MACRO
  529.         ENDM
  530.  
  531. EndPageMember    MACRO
  532.         PUTV    #PAGE_Member,d0
  533.         ENDM
  534.  
  535. ******************************************************************************
  536. *      Window class macros.
  537. ******************************************************************************
  538.  
  539. MasterGroup    MACRO
  540.         ENDM
  541.  
  542. EndMaster    MACRO
  543.         PUTV    #WINDOW_MasterGroup,d0
  544.         ENDM
  545.  
  546. ******************************************************************************
  547. *    "Quick" button creation macros.
  548. ******************************************************************************
  549.  
  550. Button        MACRO    ; label, id
  551.         ButtonObject
  552.             PUTC    LAB_Label,\1
  553.             PUTC    GA_ID,\2
  554.             PUTC    FRM_Type,FRTYPE_BUTTON
  555.         EndObject
  556.         ENDM
  557.  
  558. KeyButton    MACRO    ; label, id
  559.         ButtonObject
  560.             PUTC    LAB_Underscore,"_"
  561.             PUTC    LAB_Label,\1
  562.             PUTC    GA_ID,\2
  563.             PUTC    FRM_Type,FRTYPE_BUTTON
  564.         EndObject
  565.         ENDM
  566.  
  567. Toggle        MACRO    ; label, state, id
  568.         ToggleObject
  569.             PUTC    LAB_Label,\1
  570.             PUTC    GA_ID,\3
  571.             PUTC    GA_Selected,\2
  572.             PUTC    FRM_Type,FRTYPE_BUTTON
  573.         EndObject
  574.         ENDM
  575.  
  576. KeyToggle    MACRO    ; label, state, id
  577.         ToggleObject
  578.             PUTC    LAB_Underscore,"_"
  579.             PUTC    LAB_Label,\1
  580.             PUTC    GA_ID,\3
  581.             PUTC    GA_Selected,\2
  582.             PUTC    FRM_Type,FRTYPE_BUTTON
  583.         EndObject
  584.         ENDM
  585.  
  586. XenButton    MACRO    ; label, id
  587.         ButtonObject
  588.             PUTC    LAB_Label,\1
  589.             PUTC    GA_ID,\2
  590.             PUTC    FRM_Type,FRTYPE_XEN_BUTTON
  591.         EndObject
  592.         ENDM
  593.  
  594. XenKeyButton    MACRO    ; label, id
  595.         ButtonObject
  596.             PUTC    LAB_Underscore,"_"
  597.             PUTC    LAB_Label,\1
  598.             PUTC    GA_ID,\2
  599.             PUTC    FRM_Type,FRTYPE_XEN_BUTTON
  600.         EndObject
  601.         ENDM
  602.  
  603. XenToggle    MACRO    ; label, state, id
  604.         ToggleObject
  605.             PUTC    LAB_Label,\1
  606.             PUTC    GA_ID,\3
  607.             PUTC    GA_Selected,\2
  608.             PUTC    FRM_Type,FRTYPE_XEN_BUTTON
  609.         EndObject
  610.         ENDM
  611.  
  612. XenKeyToggle    MACRO    ; label, state, id
  613.         ToggleObject
  614.             PUTC    LAB_Underscore,"_"
  615.             PUTC    LAB_Label,\1
  616.             PUTC    GA_ID,\3
  617.             PUTC    GA_Selected,\2
  618.             PUTC    FRM_Type,FRTYPE_XEN_BUTTON
  619.         EndObject
  620.         ENDM
  621.  
  622. ******************************************************************************
  623. *    "Quick" cycle creation macros.
  624. ******************************************************************************
  625.  
  626. Cycle        MACRO    ; label, labels, active, id
  627.         CycleObject
  628.             PUTC    LAB_Label,\1
  629.             PUTC    GA_ID,\4
  630.             PUTC    FRM_Type,FRTYPE_BUTTON
  631.             PUTC    CYC_Active,\3
  632.             PUTC    CYC_Labels,\2
  633.         EndObject
  634.         ENDM
  635.  
  636. KeyCycle    MACRO    ; label, labels, active, id
  637.         CycleObject
  638.             PUTC    LAB_Underscore,"_"
  639.             PUTC    LAB_Label,\1
  640.             PUTC    GA_ID,\4
  641.             PUTC    FRM_Type,FRTYPE_BUTTON
  642.             PUTC    CYC_Active,\3
  643.             PUTC    CYC_Labels,\2
  644.         EndObject
  645.         ENDM
  646.  
  647. XenCycle    MACRO    ; label, labels, active, id
  648.         CycleObject
  649.             PUTC    LAB_Label,\1
  650.             PUTC    GA_ID,\4
  651.             PUTC    FRM_Type,FRTYPE_XEN_BUTTON
  652.             PUTC    CYC_Active,\3
  653.             PUTC    CYC_Labels,\2
  654.         EndObject
  655.         ENDM
  656.  
  657. XenKeyCycle    MACRO    ; label, labels, active, id
  658.         CycleObject
  659.             PUTC    LAB_Underscore,"_"
  660.             PUTC    LAB_Label,\1
  661.             PUTC    GA_ID,\4
  662.             PUTC    FRM_Type,FRTYPE_XEN_BUTTON
  663.             PUTC    CYC_Active,\3
  664.             PUTC    CYC_Labels,\2
  665.         EndObject
  666.         ENDM
  667.  
  668. PopCycle    MACRO    ; label, labels, active, id
  669.         CycleObject
  670.             PUTC    LAB_Label,\1
  671.             PUTC    GA_ID,\4
  672.             PUTC    FRM_Type,FRTYPE_BUTTON
  673.             PUTC    CYC_Active,\3
  674.             PUTC    CYC_Labels,\2
  675.             PUTC    CYC_Popup,1
  676.         EndObject
  677.         ENDM
  678.  
  679. KeyPopCycle    MACRO    ; label, labels, active, id
  680.         CycleObject
  681.             PUTC    LAB_Underscore,"_"
  682.             PUTC    LAB_Label,\1
  683.             PUTC    GA_ID,\4
  684.             PUTC    FRM_Type,FRTYPE_BUTTON
  685.             PUTC    CYC_Active,\3
  686.             PUTC    CYC_Labels,\2
  687.             PUTC    CYC_Popup,1
  688.         EndObject
  689.         ENDM
  690.  
  691. XenPopCycle    MACRO    ; label, labels, active, id
  692.         CycleObject
  693.             PUTC    LAB_Label,\1
  694.             PUTC    GA_ID,\4
  695.             PUTC    FRM_Type,FRTYPE_XEN_BUTTON
  696.             PUTC    CYC_Active,\3
  697.             PUTC    CYC_Labels,\2
  698.             PUTC    CYC_Popup,1
  699.         EndObject
  700.         ENDM
  701.  
  702. XenKeyPopCycle    MACRO    ; label, labels, active, id
  703.         CycleObject
  704.             PUTC    LAB_Underscore,"_"
  705.             PUTC    LAB_Label,\1
  706.             PUTC    GA_ID,\4
  707.             PUTC    FRM_Type,FRTYPE_XEN_BUTTON
  708.             PUTC    CYC_Active,\3
  709.             PUTC    CYC_Labels,\2
  710.             PUTC    CYC_Popup,1
  711.         EndObject
  712.         ENDM
  713.  
  714. ******************************************************************************
  715. *    "Quick" checkbox creation macros.
  716. ******************************************************************************
  717.  
  718. CheckBox    MACRO    ; label, state, id
  719.         CheckBoxObject
  720.             PUTC    LAB_Label,\1
  721.             PUTC    GA_ID,\3
  722.             PUTC    FRM_Type,FRTYPE_BUTTON
  723.             PUTC    FRM_EdgesOnly,1
  724.             PUTC    GA_Selected,\2
  725.         EndObject
  726.         ENDM
  727.  
  728. KeyCheckBox    MACRO    ; label, state, id
  729.         CheckBoxObject
  730.             PUTC    LAB_Underscore,"_"
  731.             PUTC    LAB_Label,\1
  732.             PUTC    GA_ID,\3
  733.             PUTC    FRM_Type,FRTYPE_BUTTON
  734.             PUTC    FRM_EdgesOnly,1
  735.             PUTC    GA_Selected,\2
  736.         EndObject
  737.         ENDM
  738.  
  739. XenCheckBox    MACRO    ; label, state, id
  740.         CheckBoxObject
  741.             PUTC    LAB_Label,\1
  742.             PUTC    GA_ID,\3
  743.             PUTC    FRM_Type,FRTYPE_XEN_BUTTON
  744.             PUTC    FRM_EdgesOnly,1
  745.             PUTC    GA_Selected,\2
  746.         EndObject
  747.         ENDM
  748.  
  749. XenKeyCheckBox    MACRO    ; label, state, id
  750.         CheckBoxObject
  751.             PUTC    LAB_Underscore,"_"
  752.             PUTC    LAB_Label,\1
  753.             PUTC    GA_ID,\3
  754.             PUTC    FRM_Type,FRTYPE_XEN_BUTTON
  755.             PUTC    FRM_EdgesOnly,1
  756.             PUTC    GA_Selected,\2
  757.         EndObject
  758.         ENDM
  759.  
  760. ******************************************************************************
  761. *    "Quick" info object creation macros.
  762. ******************************************************************************
  763.  
  764. InfoFixed    MACRO    ; label, text, args, numlines
  765.         InfoObject
  766.             PUTC    LAB_Label,\1
  767.             PUTC    FRM_Type,FRTYPE_BUTTON
  768.             PUTC    FRM_Recessed,1
  769.             PUTC    INFO_TextFormat,\2
  770.             PUTC    INFO_Args,\3
  771.             PUTC    INFO_MinLines,\4
  772.             PUTC    INFO_FixTextWidth,1
  773.         EndObject
  774.         ENDM
  775.  
  776. InfoObj         MACRO    ; label, text, args, numlines
  777.         InfoObject
  778.             PUTC    LAB_Label,\1
  779.             PUTC    FRM_Type,FRTYPE_BUTTON
  780.             PUTC    FRM_Recessed,1
  781.             PUTC    INFO_TextFormat,\2
  782.             PUTC    INFO_Args,\3
  783.             PUTC    INFO_MinLines,\4
  784.         EndObject
  785.         ENDM
  786.  
  787. ******************************************************************************
  788. *    "Quick" string/integer creation macros.
  789. ******************************************************************************
  790.  
  791. String        MACRO    ; label, contents, maxchars, id
  792.         StringObject
  793.             PUTC    LAB_Label,\1
  794.             PUTC    FRM_Type,FRTYPE_RIDGE
  795.             PUTC    GA_ID,\4
  796.             PUTC    STRINGA_TextVal,\2
  797.             PUTC    STRINGA_MaxChars,\3
  798.         EndObject
  799.         ENDM
  800.  
  801. KeyString    MACRO    ; label, contents, maxchars, id
  802.         StringObject
  803.             PUTC    LAB_Underscore,"_"
  804.             PUTC    LAB_Label,\1
  805.             PUTC    FRM_Type,FRTYPE_RIDGE
  806.             PUTC    GA_ID,\4
  807.             PUTC    STRINGA_TextVal,\2
  808.             PUTC    STRINGA_MaxChars,\3
  809.         EndObject
  810.         ENDM
  811.  
  812. TabString    MACRO    ; label, contents, maxchars, id
  813.         StringObject
  814.             PUTC    LAB_Label,\1
  815.             PUTC    FRM_Type,FRTYPE_RIDGE
  816.             PUTC    GA_ID,\4
  817.             PUTC    GA_TabCycle,1
  818.             PUTC    STRINGA_TextVal,\2
  819.             PUTC    STRINGA_MaxChars,\3
  820.         EndObject
  821.         ENDM
  822.  
  823. TabKeyString    MACRO    ; label, contents, maxchars, id
  824.         StringObject
  825.             PUTC    LAB_Underscore,"_"
  826.             PUTC    LAB_Label,\1
  827.             PUTC    FRM_Type,FRTYPE_RIDGE
  828.             PUTC    GA_ID,\4
  829.             PUTC    GA_TabCycle,1
  830.             PUTC    STRINGA_TextVal,\2
  831.             PUTC    STRINGA_MaxChars,\3
  832.         EndObject
  833.         ENDM
  834.  
  835. Integer         MACRO    ; label, contents, maxchars, id
  836.         StringObject
  837.             PUTC    LAB_Label,\1
  838.             PUTC    FRM_Type,FRTYPE_RIDGE
  839.             PUTC    GA_ID,\4
  840.             PUTC    STRINGA_LongVal,\2
  841.             PUTC    STRINGA_MaxChars,\3
  842.         EndObject
  843.         ENDM
  844.  
  845. KeyInteger    MACRO    ; label, contents, maxchars, id
  846.         StringObject
  847.             PUTC    LAB_Underscore,"_"
  848.             PUTC    LAB_Label,\1
  849.             PUTC    FRM_Type,FRTYPE_RIDGE
  850.             PUTC    GA_ID,\4
  851.             PUTC    STRINGA_LongVal,\2
  852.             PUTC    STRINGA_MaxChars,\3
  853.         EndObject
  854.         ENDM
  855.  
  856. TabInteger    MACRO    ; label, contents, maxchars, id
  857.         StringObject
  858.             PUTC    LAB_Label,\1
  859.             PUTC    FRM_Type,FRTYPE_RIDGE
  860.             PUTC    GA_ID,\4
  861.             PUTC    GA_TabCycle,1
  862.             PUTC    STRINGA_LongVal,\2
  863.             PUTC    STRINGA_MaxChars,\3
  864.         EndObject
  865.         ENDM
  866.  
  867. TabKeyInteger    MACRO    ; label, contents, maxchars, id
  868.         StringObject
  869.             PUTC    LAB_Underscore,"_"
  870.             PUTC    LAB_Label,\1
  871.             PUTC    FRM_Type,FRTYPE_RIDGE
  872.             PUTC    GA_ID,\4
  873.             PUTC    GA_TabCycle,1
  874.             PUTC    STRINGA_LongVal,\2
  875.             PUTC    STRINGA_MaxChars,\3
  876.         EndObject
  877.         ENDM
  878.  
  879. ******************************************************************************
  880. *    "Quick" scroller creation macros.
  881. ******************************************************************************
  882.  
  883. HorizScroller    MACRO    ; label, top, total, visible, id
  884.         PropObject
  885.             PUTC    LAB_Label,\1
  886.             PUTC    PGA_Top,\2
  887.             PUTC    PGA_Total,\3
  888.             PUTC    PGA_Visible,\4
  889.             PUTC    PGA_Freedom,FREEHORIZ
  890.             PUTC    GA_ID,\5
  891.             PUTC    PGA_Arrows,1
  892.         EndObject
  893.         ENDM
  894.  
  895. VertScroller    MACRO    ; label, top, total, visible, id
  896.         PropObject
  897.             PUTC    LAB_Label,\1
  898.             PUTC    PGA_Top,\2
  899.             PUTC    PGA_Total,\3
  900.             PUTC    PGA_Visible,\4
  901.             PUTC    GA_ID,\5
  902.             PUTC    PGA_Arrows,1
  903.         EndObject
  904.         ENDM
  905.  
  906. KeyHorizScroller MACRO     ; label, top, total, visible, id
  907.         PropObject
  908.             PUTC    LAB_Underscore,"_"
  909.             PUTC    LAB_Label,\1
  910.             PUTC    PGA_Top,\2
  911.             PUTC    PGA_Total,\3
  912.             PUTC    PGA_Visible,\4
  913.             PUTC    PGA_Freedom,FREEHORIZ
  914.             PUTC    GA_ID,\5
  915.             PUTC    PGA_Arrows,1
  916.         EndObject
  917.         ENDM
  918.  
  919. KeyVertScroller MACRO    ; label, top, total, visible, id
  920.         PropObject
  921.             PUTC    LAB_Underscore,"_"
  922.             PUTC    LAB_Label,\1
  923.             PUTC    PGA_Top,\2
  924.             PUTC    PGA_Total,\3
  925.             PUTC    PGA_Visible,\4
  926.             PUTC    GA_ID,\5
  927.             PUTC    PGA_Arrows,1
  928.         EndObject
  929.         ENDM
  930.  
  931. ******************************************************************************
  932. *    "Quick" indicator creation macros.
  933. ******************************************************************************
  934.  
  935. Indicator    MACRO    ; min, max, level, just
  936.         IndicatorObject
  937.             PUTC    INDIC_Min,\1
  938.             PUTC    INDIC_Max,\2
  939.             PUTC    INDIC_Level,\3
  940.             PUTC    INDIC_Justification,\4
  941.         EndObject
  942.         ENDM
  943.  
  944. IndicatorFormat MACRO    ; min, max, level, just, fstring
  945.         IndicatorObject
  946.             PUTC    INDIC_Min,\1
  947.             PUTC    INDIC_Max,\2
  948.             PUTC    INDIC_Level,\3
  949.             PUTC    INDIC_Justification,\4
  950.             PUTC    INDIC_FormatString,\5
  951.         EndObject
  952.         ENDM
  953.  
  954. ******************************************************************************
  955. *    "Quick" progress creation macros.
  956. ******************************************************************************
  957.  
  958. HorizProgress    MACRO    ; label, min, max, done
  959.         ProgressObject
  960.             PUTC    LAB_Label,\1
  961.             PUTC    FRM_Type,FRTYPE_BUTTON
  962.             PUTC    FRM_Recessed,1
  963.             PUTC    PROGRESS_Min,\2
  964.             PUTC    PROGRESS_Max,\3
  965.             PUTC    PROGRESS_Done,\4
  966.         EndObject
  967.         ENDM
  968.  
  969. VertProgress   MACRO   ; label, min, max, done
  970.         ProgressObject
  971.             PUTC    LAB_Label,\1
  972.             PUTC    FRM_Type,FRTYPE_BUTTON
  973.             PUTC    FRM_Recessed,1
  974.             PUTC    PROGRESS_Min,\2
  975.             PUTC    PROGRESS_Max,\3
  976.             PUTC    PROGRESS_Done,\4
  977.             PUTC    PROGRESS_Vertical,1
  978.         EndObject
  979.         ENDM
  980.  
  981. ******************************************************************************
  982. *    "Quick" slider creation macros.
  983. ******************************************************************************
  984.  
  985. HorizSlider    MACRO    ; label, min, max, level, id
  986.         SliderObject
  987.             PUTC    LAB_Label,\1
  988.             PUTC    SLIDER_Min,\2
  989.             PUTC    SLIDER_Max,\3
  990.             PUTC    SLIDER_Level,\4
  991.             PUTC    GA_ID,\5
  992.         EndObject
  993.         ENDM
  994.  
  995. VertSlider    MACRO    ; label, min, max, level, id
  996.         SliderObject
  997.             PUTC    LAB_Label,\1
  998.             PUTC    SLIDER_Min,\2
  999.             PUTC    SLIDER_Max,\3
  1000.             PUTC    SLIDER_Level,\4
  1001.             PUTC    PGA_Freedom,FREEVERT
  1002.             PUTC    GA_ID,\5
  1003.         EndObject
  1004.         ENDM
  1005.  
  1006. KeyHorizSlider    MACRO    ; label, min, max, level, id
  1007.         SliderObject
  1008.             PUTC    LAB_Underscore,"_"
  1009.             PUTC    LAB_Label,\1
  1010.             PUTC    SLIDER_Min,\2
  1011.             PUTC    SLIDER_Max,\3
  1012.             PUTC    SLIDER_Level,\4
  1013.             PUTC    GA_ID,\5
  1014.         EndObject
  1015.         ENDM
  1016.  
  1017. KeyVertSlider    MACRO    ; label, min, max, level, id
  1018.         SliderObject
  1019.             PUTC    LAB_Underscore,"_"
  1020.             PUTC    LAB_Label,\1
  1021.             PUTC    SLIDER_Min,\2
  1022.             PUTC    SLIDER_Max,\3
  1023.             PUTC    SLIDER_Level,\4
  1024.             PUTC    PGA_Freedom,FREEVERT
  1025.             PUTC    GA_ID,\5
  1026.         EndObject
  1027.         ENDM
  1028.  
  1029. ******************************************************************************
  1030. *    "Quick" mx creation macros.
  1031. ******************************************************************************
  1032.  
  1033. RightMx         MACRO    ; label, labels, active, id
  1034.         MxObject
  1035.             PUTC    GROUP_Style,GRSTYLE_VERTICAL
  1036.             PUTC    LAB_Label,\1
  1037.             PUTC    MX_Labels,\2
  1038.             PUTC    MX_Active,\3
  1039.             PUTC    GA_ID,\4
  1040.         EndObject
  1041.         ENDM
  1042.  
  1043. LeftMx        MACRO    ; label, labels, active, id
  1044.         MxObject
  1045.             PUTC    GROUP_Style,GRSTYLE_VERTICAL
  1046.             PUTC    LAB_Label,\1
  1047.             PUTC    MX_Labels,\2
  1048.             PUTC    MX_Active,\3
  1049.             PUTC    MX_LabelPlace,PLACE_LEFT
  1050.             PUTC    GA_ID,\4
  1051.         EndObject
  1052.         ENDM
  1053.  
  1054. RightMxKey    MACRO    ; label, labels, active, id
  1055.         MxObject
  1056.             PUTC    GROUP_Style,GRSTYLE_VERTICAL
  1057.             PUTC    LAB_Underscore,"_"
  1058.             PUTC    LAB_Label,\1
  1059.             PUTC    MX_Labels,\2
  1060.             PUTC    MX_Active,\3
  1061.             PUTC    GA_ID,\4
  1062.         EndObject
  1063.         ENDM
  1064.  
  1065. LeftMxKey    MACRO    ; label, labels, active, id
  1066.         MxObject
  1067.             PUTC    GROUP_Style,GRSTYLE_VERTICAL
  1068.             PUTC    LAB_Underscore,"_"
  1069.             PUTC    LAB_Label,\1
  1070.             PUTC    MX_Labels,\2
  1071.             PUTC    MX_Active,\3
  1072.             PUTC    MX_LabelPlace,PLACE_LEFT
  1073.             PUTC    GA_ID,\4
  1074.         EndObject
  1075.         ENDM
  1076.  
  1077. Tabs        MACRO    ; label, labels, active, id
  1078.         MxObject
  1079.             PUTC    LAB_Label,\1
  1080.             PUTC    MX_TabsObject,1
  1081.             PUTC    MX_Labels,\2
  1082.             PUTC    MX_Active,\3
  1083.             PUTC    GA_ID,\4
  1084.         EndObject
  1085.         ENDM
  1086.  
  1087. TabsKey         MACRO    ; label, labels, active, id
  1088.         MxObject
  1089.             PUTC    LAB_Underscore,"_"
  1090.             PUTC    LAB_Label,\1
  1091.             PUTC    MX_TabsObject,1
  1092.             PUTC    MX_Labels,\2
  1093.             PUTC    MX_Active,\3
  1094.             PUTC    GA_ID,\4
  1095.         EndObject
  1096.         ENDM
  1097.  
  1098. TabsEqual    MACRO    ; label, labels, active, id
  1099.         MxObject
  1100.             PUTC    GROUP_EqualWidth,1
  1101.             PUTC    LAB_Label,\1
  1102.             PUTC    MX_TabsObject,1
  1103.             PUTC    MX_Labels,\2
  1104.             PUTC    MX_Active,\3
  1105.             PUTC    GA_ID,\4
  1106.         EndObject
  1107.         ENDM
  1108.  
  1109. TabsEqualKey    MACRO    ; label, labels, active, id
  1110.         MxObject
  1111.             PUTC    GROUP_EqualWidth,1
  1112.             PUTC    LAB_Underscore,"_"
  1113.             PUTC    LAB_Label,\1
  1114.             PUTC    MX_TabsObject,1
  1115.             PUTC    MX_Labels,\2
  1116.             PUTC    MX_Active,\3
  1117.             PUTC    GA_ID,\4
  1118.         EndObject
  1119.         ENDM
  1120.  
  1121. ******************************************************************************
  1122. *    "Quick" listview creation macros.
  1123. ******************************************************************************
  1124.  
  1125. StrListview    MACRO    ; label, strings, id
  1126.         ListviewObject
  1127.             PUTC    LAB_Label,\1
  1128.             PUTC    GA_ID,\3
  1129.             PUTC    LISTV_EntryArray,\2
  1130.         EndObject
  1131.         ENDM
  1132.  
  1133. StrListviewSorted MACRO   ; label, strings, id
  1134.         ListviewObject
  1135.             PUTC    LAB_Label,\1
  1136.             PUTC    GA_ID,\3
  1137.             PUTC    LISTV_EntryArray,\2
  1138.             PUTC    LISTV_SortEntryArray,1
  1139.         EndObject
  1140.         ENDM
  1141.  
  1142. ReadStrListview MACRO    ; label, strings
  1143.         ListviewObject
  1144.             PUTC    LAB_Label,\1
  1145.             PUTC    LISTV_EntryArray,\2
  1146.             PUTC    LISTV_ReadOnly,1
  1147.         EndObject
  1148.         ENDM
  1149.  
  1150. ReadStrListviewSorted MACRO   ; label, strings
  1151.         ListviewObject
  1152.             PUTC    LAB_Label,\1
  1153.             PUTC    LISTV_EntryArray,\2
  1154.             PUTC    LISTV_SortEntryArray,1
  1155.             PUTC    LISTV_ReadOnly,1
  1156.         EndObject
  1157.         ENDM
  1158.  
  1159. MultiStrListview MACRO     ; label, strings, id
  1160.         ListviewObject
  1161.             PUTC    LAB_Label,\1
  1162.             PUTC    GA_ID,\3
  1163.             PUTC    LISTV_EntryArray,\2
  1164.             PUTC    LISTV_MultiSelect,1
  1165.         EndObject
  1166.         ENDM
  1167.  
  1168. MultiStrListviewSorted MACRO   ; label, strings, id
  1169.         ListviewObject
  1170.             PUTC    LAB_Label,\1
  1171.             PUTC    GA_ID,\3
  1172.             PUTC    LISTV_EntryArray,\2
  1173.             PUTC    LISTV_SortEntryArray,1
  1174.             PUTC    LISTV_MultiSelect,1
  1175.         EndObject
  1176.         ENDM
  1177.  
  1178. ******************************************************************************
  1179. *    "Quick" separator bar creation macros.
  1180. ******************************************************************************
  1181.  
  1182. VertSeparator    MACRO
  1183.         SeparatorObject
  1184.         EndObject
  1185.         ENDM
  1186.  
  1187. VertThinSeparator MACRO
  1188.         SeparatorObject
  1189.             PUTC    SEP_Thin,1
  1190.         EndObject
  1191.         ENDM
  1192.  
  1193. HorizSeparator    MACRO
  1194.         SeparatorObject
  1195.             PUTC    SEP_Horiz,1
  1196.         EndObject
  1197.         ENDM
  1198.  
  1199. TitleSeparator    MACRO    ; title
  1200.         SeparatorObject
  1201.             PUTC    SEP_Horiz,1
  1202.             PUTC    SEP_Title,\1
  1203.         EndObject
  1204.         ENDM
  1205.  
  1206. HTitleSeparator MACRO    ; title
  1207.         SeparatorObject
  1208.             PUTC    SEP_Horiz,1
  1209.             PUTC    SEP_Title,\1
  1210.             PUTC    SEP_Highlight,1
  1211.         EndObject
  1212.         ENDM
  1213.  
  1214. CTitleSeparator MACRO    ; title
  1215.         SeparatorObject
  1216.             PUTC    SEP_Horiz,1
  1217.             PUTC    SEP_Title,\1
  1218.             PUTC    SEP_CenterTitle,1
  1219.         EndObject
  1220.         ENDM
  1221.  
  1222. CHTitleSeparator MACRO     ; title
  1223.         SeparatorObject
  1224.             PUTC    SEP_Horiz,1
  1225.             PUTC    SEP_Title,\1
  1226.             PUTC    SEP_Highlight,1
  1227.             PUTC    SEP_CenterTitle,1
  1228.         EndObject
  1229.         ENDM
  1230.  
  1231. ** Typos
  1232. VertSeperator    MACRO
  1233.         VertSeparator
  1234.         ENDM
  1235.  
  1236. VertThinSeperator MACRO
  1237.         VertThinSeparator
  1238.         ENDM
  1239.  
  1240. HorizSeperator    MACRO
  1241.         HorizSeparator
  1242.         ENDM
  1243.  
  1244. TitleSeperator    MACRO
  1245.         TitleSeparator
  1246.         ENDM
  1247.  
  1248. HTitleSeperator MACRO
  1249.         HTitleSeparator
  1250.         ENDM
  1251.  
  1252. CTitleSeperator MACRO
  1253.         CTitleSeparator
  1254.         ENDM
  1255.  
  1256. CHTitleSeperator MACRO
  1257.         CHTitleSeparator
  1258.         ENDM
  1259.  
  1260. ******************************************************************************
  1261. *    Base class method macros.
  1262. ******************************************************************************
  1263.  
  1264. AddMap        MACRO    ; object, target, map
  1265.         DOMETHOD \1,#BASE_ADDMAP,\2,\3
  1266.         ENDM
  1267.  
  1268. AddCondit    MACRO    ; object, target, ttag, tdat, ftag, fdat, stag, sdat
  1269.         DOMETHOD \1,#BASE_ADDCONDITIONAL,\2,\3,\4,\5,\6,\7,\8
  1270.         ENDM
  1271.  
  1272. AddHook         MACRO    ; object, hook
  1273.         DOMETHOD \1,#BASE_ADDHOOK,\2
  1274.         ENDM
  1275.  
  1276. RemMap        MACRO    ; object, target
  1277.         DOMETHOD \1,#BASE_REMMAP,\2
  1278.         ENDM
  1279.  
  1280. RemCondit    MACRO    ; object, target
  1281.         DOMETHOD \1,#BASE_REMCONDITIONAL,\2
  1282.         ENDM
  1283.  
  1284. RemHook         MACRO    ; object, hook
  1285.         DOMETHOD \1,#BASE_REMHOOK,\2
  1286.         ENDM
  1287.  
  1288. ******************************************************************************
  1289. *    Listview class method macros.
  1290. ******************************************************************************
  1291.  
  1292.         ** Requires BGUIBase in A6!
  1293. AddEntry    MACRO    ; window, object, entry, how
  1294.         DOGADGETMETHOD \2,\1,0,#LVM_ADDSINGLE,0,\3,\4,0
  1295.         ENDM
  1296.  
  1297.         ** Requires BGUIBase in A6!
  1298. AddEntryVisible MACRO    ; window, object, entry, how
  1299.         DOGADGETMETHOD \2,\1,0,#LVM_ADDSINGLE,0,\3,\4,#LVASF_MAKEVISIBLE
  1300.         ENDM
  1301.  
  1302.         ** Requires BGUIBase in A6!
  1303. AddEntrySelect    MACRO    ; window, object, entry, how
  1304.         DOGADGETMETHOD \2,\1,0,#LVM_ADDSINGLE,0,\3,\4,#LVASF_SELECT
  1305.         ENDM
  1306.  
  1307.         ** Requires BGUIBase in A6!
  1308. ClearList    MACRO    ; window object
  1309.         DOGADGETMETHOD \2,\1,0,#LVM_CLEAR,0
  1310.         ENDM
  1311.  
  1312. FirstEntry    MACRO    ; object
  1313.         DOMETHOD \1,#LVM_FIRSTENTRY,0,0
  1314.         ENDM
  1315.  
  1316. FirstSelected    MACRO    ; object
  1317.         DOMETHOD \1,#LVM_FIRSTENTRY,0,#LVGEF_SELECTED
  1318.         ENDM
  1319.  
  1320. LastEntry    MACRO    ; object
  1321.         DOMETHOD \1,#LVM_LASTENTRY,0,0
  1322.         ENDM
  1323.  
  1324. LastSelected    MACRO    ; object
  1325.         DOMETHOD \1,#LVM_LASTENTRY,0,#LVGEF_SELECTED
  1326.         ENDM
  1327.  
  1328. NextEntry    MACRO    ; object, last
  1329.         DOMETHOD \1,#LVM_NEXTENTRY,\2,0
  1330.         ENDM
  1331.  
  1332. NextSelected    MACRO    ; object, last
  1333.         DOMETHOD \1,#LVM_NEXTENTRY,\2,#LVGEF_SELECTED
  1334.         ENDM
  1335.  
  1336. PrevEntry    MACRO    ; object, last
  1337.         DOMETHOD \1,#LVM_PREVENTRY,\2,0
  1338.         ENDM
  1339.  
  1340. PrevSelected    MACRO    ; object, last
  1341.         DOMETHOD \1,#LVM_PREVENTRY,\2,#LVGEF_SELECTED
  1342.         ENDM
  1343.  
  1344. RemoveEntry    MACRO    ; object, entry
  1345.         DOMETHOD \1,#LVM_REMENTRY,0,\2
  1346.         ENDM
  1347.  
  1348.         ** Requires BGUIBase in A6!
  1349. RemoveEntryVisible MACRO ; window, object, entry
  1350.         DOGADGETMETHOD \2,\1,0,#LVM_REMENTRY,0,\3
  1351.         ENDM
  1352.  
  1353.         ** Requires BGUIBase in A6!
  1354. RefreshList    MACRO    ; window, object
  1355.         DOGADGETMETHOD \2,\1,0,#LVM_REFRESH,0
  1356.         ENDM
  1357.  
  1358.         ** Requires BGUIBase in A6!
  1359. SortList    MACRO    ; window, object
  1360.         DOGADGETMETHOD \2,\1,0,#LVM_SORT,0
  1361.         ENDM
  1362.  
  1363. LockList    MACRO    ; object
  1364.         DOMETHOD \1,#LVM_LOCKLIST,0
  1365.         ENDM
  1366.  
  1367.         ** Requires BGUIBase in A6!
  1368. UnlockList    MACRO    ; window, object
  1369.         DOGADGETMETHOD \2,\1,0,#LVM_UNLOCKLIST,0
  1370.         ENDM
  1371.  
  1372.         ** Requires BGUIBase in A6!
  1373. MoveEntry    MACRO    ; window, object, entry, dir
  1374.         DOGADGETMETHOD \2,\1,0,#LVM_MOVE,0,\3,\4
  1375.         ENDM
  1376.  
  1377.         ** Requires BGUIBase in A6!
  1378. MoveSelectedEntry MACRO ; window, object, dir
  1379.         DOGADGETMETHOD \2,\1,0,#LVM_MOVE,0,0,\3
  1380.         ENDM
  1381.  
  1382.         ** Requires BGUIBase in A6!
  1383. ReplaceEntry    MACRO ; window, object, old, new
  1384.         DOGADGETMETHOD \2,\1,0,#LVM_REPLACE,0,\3,\4
  1385.         ENDM
  1386.  
  1387. ******************************************************************************
  1388. *    Window class method macros.
  1389. ******************************************************************************
  1390.  
  1391. GadgetKey    MACRO    ; wobj, gobj, key
  1392.         DOMETHOD \1,#WM_GADGETKEY,0,\2,\3
  1393.         ENDM
  1394.  
  1395. xWindowOpen    MACRO    ; wobj
  1396.         DOMETHOD \1,#WM_OPEN
  1397.         ENDM
  1398.  
  1399. WindowClose    MACRO    ; wobj
  1400.         DOMETHOD \1,#WM_CLOSE
  1401.         ENDM
  1402.  
  1403. WindowBusy    MACRO    ; wobj
  1404.         DOMETHOD \1,#WM_SLEEP
  1405.         ENDM
  1406.  
  1407. WindowReady    MACRO    ; wobj
  1408.         DOMETHOD \1,#WM_WAKEUP
  1409.         ENDM
  1410.  
  1411. HandleEvent    MACRO    ; wobj
  1412.         DOMETHOD \1,#WM_HANDLEIDCMP
  1413.         ENDM
  1414.  
  1415. DisableMenu    MACRO    ; wobj, id, set
  1416.         DOMETHOD \1,#WM_DISABLEMENU,\2,\3
  1417.         ENDM
  1418.  
  1419. CheckItem    MACRO    ; wobj, id, set
  1420.         DOMETHOD \1,#WM_CHECKITEM,\2,\3
  1421.         ENDM
  1422.  
  1423. MenuDisabled    MACRO    ; wobj, id
  1424.         DOMETHOD \1,#WM_MENUDISABLED,\2
  1425.         ENDM
  1426.  
  1427. ItemChecked    MACRO    ; wobj, id
  1428.         DOMETHOD \1,#WM_ITEMCHECED,\2
  1429.         ENDM
  1430.  
  1431. GetAppMsg    MACRO    ; wobj
  1432.         DOMETHOD \1,#WM_GETAPPMSG
  1433.         ENDM
  1434.  
  1435. AddUpdate    MACRO    ; wobj, id, target, map
  1436.         DOMETHOD \1,#WM_ADDUPDATE,\2,\3,\4
  1437.         ENDM
  1438.  
  1439. GetSignalWindow MACRO    ; wobj
  1440.         DOMETHOD \1,#WM_GET_SIGNAL_WINDOW
  1441.         ENDM
  1442.  
  1443. ******************************************************************************
  1444. *    Commodity class method macros.
  1445. ******************************************************************************
  1446.  
  1447. AddHotKey    MACRO    ; broker, desc, id, flags
  1448.         DOMETHOD \1,#CM_ADDHOTKEY,\2,\3,\4
  1449.         ENDM
  1450.  
  1451. RemHotKey    MACRO    ; broker, id
  1452.         DOMETHOD \1,#CM_REMHOTKEY,\2
  1453.         ENDM
  1454.  
  1455. DisableHotKey    MACRO    ; broker, id
  1456.         DOMETHOD \1,#CM_DISABLEHOTKEY,\2
  1457.         ENDM
  1458.  
  1459. EnableHotKey    MACRO    ; broker, id
  1460.         DOMETHOD \1,#CM_ENABLEHOTKEY,\2
  1461.         ENDM
  1462.  
  1463. EnableBroker    MACRO    ; broker
  1464.         DOMETHOD \1,#CM_ENABLEBROKER
  1465.         ENDM
  1466.  
  1467. DisableBroker    MACRO    ; broker
  1468.         DOMETHOD \1,#CM_DISABLEBROKER
  1469.         ENDM
  1470.  
  1471. MsgInfo         MACRO    ; broker, type, id, data
  1472.         DOMETHOD \1,#CM_MSGINFO,\2,\3,\4
  1473.         ENDM
  1474.  
  1475. ******************************************************************************
  1476. *    FileReq class method macros.
  1477. ******************************************************************************
  1478.  
  1479. DoRequest    MACRO    ; object
  1480.         DOMETHOD \1,#FRM_DOREQUEST
  1481.         ENDM
  1482.  
  1483.         ENDC ; LIBRARIES_BGUI_MACROS_I
  1484.